package cn.spring.dao.impl;

import cn.spring.dao.Ink;

import java.awt.*;

public class GreyInk implements Ink {
    //打印采用灰色
    public String getColor(int r,int g,int b){
        int c= (r+g+b)/3;
        Color color = new Color(c,c,c);
        return "#"+Integer.toHexString(color.getRGB()).substring(2);
    }
}
